import React from 'react';
import { Typography } from '@mui/material';
import ActionDialog from './ActionDialog';

interface NewModelDialogProps {
  open?: boolean;
  onRequestClose?: () => void;
  [key: string]: any;
}

/**
 * NewModelDialog Component
 * Dialog for creating a new model (deletes current model)
 */
const NewModelDialog: React.FC<NewModelDialogProps> = ({
  open = false,
  onRequestClose,
  ...otherProps
}) => {
  return (
    <ActionDialog
      message="Creating new model..."
      style={{ textAlign: 'center' }}
      args={{
        tab: 'define',
        action: 'deleteModel',
      }}
      buttonLabel="CREATE"
      title="Create new model"
      open={open}
      onRequestClose={onRequestClose}
      {...otherProps}
    >
      <Typography variant="h6" sx={{ color: 'text.primary', mt: 2 }}>
        The current model will be deleted
      </Typography>
    </ActionDialog>
  );
};

export default NewModelDialog;

